<template>
  <el-dialog v-model="open" title="详情" width="600px" append-to-body :close-on-click-modal="false">
    <el-descriptions class="margin-top" :column="2">
      <el-descriptions-item label="场地">{{ form.siteName }}</el-descriptions-item>
      <el-descriptions-item label="项目">{{ form.projectName }}</el-descriptions-item>
      <el-descriptions-item label="预订时间">{{ form.orderDate }}</el-descriptions-item>
      <el-descriptions-item label="订单编号">{{ form.orderCode }}</el-descriptions-item>
      <el-descriptions-item label="会员姓名">{{ form.orderName }}</el-descriptions-item>
      <el-descriptions-item label="手机号">{{ form.orderTelno }}</el-descriptions-item>
      <el-descriptions-item label="会员卡类型">{{ form.memberCardName }}</el-descriptions-item>
      <el-descriptions-item label="订场时长">{{ form.orderHour }} 小时</el-descriptions-item>
      <el-descriptions-item label="订单金额">{{ form.orderAmount }}</el-descriptions-item>
      <el-descriptions-item label="优惠金额">{{ decimalTo2(form.orderAmount-form.finalOrderAmount) }}</el-descriptions-item>
      <el-descriptions-item label="折后金额">{{ form.finalOrderAmount }}</el-descriptions-item>
      <el-descriptions-item label="支付状态">{{ form.payStatusStr }}</el-descriptions-item>
      <el-descriptions-item label="支付方式">{{ form.payTypeStr }}</el-descriptions-item>
      <el-descriptions-item label="操作员">{{ form.operatorName }}</el-descriptions-item>
    </el-descriptions>
  </el-dialog>
</template>

<script setup>
import { toRefs } from '@vueuse/shared'
import { computed } from '@vue/reactivity'
import { decimalTo2 } from '../../../../../utils/ruoyi'


const props = defineProps({
  props: {
    type: Object,
    default: () => ({
      open: false,
      data: {}
    })
  }
})
const { open } = toRefs(props.props)
const form = computed(() => props.props.data)

</script>

<style scoped>

</style>
